﻿<%@ Page Language="C#" MasterPageFile="~/Admin/admin.master" AutoEventWireup="true"
    CodeFile="Supplier.aspx.cs" Inherits="Admin_Supplier" Title="Supplier List" %>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" runat="Server">
    Supplier List</asp:Content>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <data:GridViewSearchPanel ID="GridViewSearchPanel1" runat="server" GridViewControlID="GridView1"
        PersistenceMethod="Session" />
    <br />
    <data:EntityGridView ID="GridView1" runat="server" AutoGenerateColumns="False" OnSelectedIndexChanged="GridView1_SelectedIndexChanged"
        DataSourceID="SupplierDataSource" DataKeyNames="SupplierId" AllowMultiColumnSorting="false"
        DefaultSortColumnName="" DefaultSortDirection="Ascending" ExcelExportFileName="Export_Supplier.xls"
        AllowPaging="True">
        <Columns>
            <asp:CommandField ShowSelectButton="True" ShowEditButton="True" />
            <asp:BoundField DataField="Phone" HeaderText="Phone" SortExpression="[Phone]" />
            <asp:BoundField DataField="Remark" HeaderText="Remark" SortExpression="[Remark]" />
            <asp:BoundField DataField="Address" HeaderText="Address" SortExpression="[Address]" />
            <asp:BoundField DataField="SupplierId" HeaderText="Supplier Id" SortExpression="[SupplierId]"
                ReadOnly="True" />
            <asp:BoundField DataField="SupplierName" HeaderText="Supplier Name" SortExpression="[SupplierName]" />
        </Columns>
        <EmptyDataTemplate>
            <b>No Supplier Found!</b>
        </EmptyDataTemplate>
    </data:EntityGridView>
    <br />
    <asp:Button runat="server" ID="btnSupplier" OnClientClick="javascript:location.href='SupplierEdit.aspx'; return false;"
        Text="Add New"></asp:Button>
    <data:SupplierDataSource ID="SupplierDataSource" runat="server" SelectMethod="GetPaged"
        EnablePaging="True" EnableSorting="True">
        <Parameters>
            <data:CustomParameter Name="WhereClause" Value="" ConvertEmptyStringToNull="false" />
            <data:CustomParameter Name="OrderByClause" Value="" ConvertEmptyStringToNull="false" />
            <asp:ControlParameter Name="PageIndex" ControlID="GridView1" PropertyName="PageIndex"
                Type="Int32" />
            <asp:ControlParameter Name="PageSize" ControlID="GridView1" PropertyName="PageSize"
                Type="Int32" />
            <data:CustomParameter Name="RecordCount" Value="0" Type="Int32" />
        </Parameters>
    </data:SupplierDataSource>
</asp:Content>
